package com.study.zzedu.fragment.tab.notice;

import android.content.Context;

import com.study.zzedu.base.BasePresenter;
import com.study.zzedu.base.BaseView;
import com.study.zzedu.http.OnResultListener;

public class CourseNoticePresenter extends BasePresenter<BaseView> {
    private CourseNoticeModel tModel;
    public CourseNoticePresenter(){
        this.tModel = new CourseNoticeModel();
    }

    public void getCourseNoticeInfo(Context context,String courseCode){
        tModel.getCourseNoticeInfo(context,courseCode,new OnResultListener() {
            @Override
            public void onSuccess(String result) {
                getView().getData(result);
            }

            @Override
            public void onError(String error) {
                getView().showError(error);
            }
        });
    }
}
